<%@ page contentType="text/html;charset=UTF-8" %>
<%@ taglib uri="/WEB-INF/tlds/jpage-jbpm.tld" prefix="jpage" %>
<%@ page import="java.util.*" %>
<%@ page import="org.jbpm.graph.def.*" %>
<%@ page import="org.jbpm.graph.exe.*" %>
<%@ page import="org.jbpm.db.*" %>
<%@ page import="org.jbpm.*" %>
<%@ page import="com.gzgi.workflow.jbpm.model.*" %>
<%@ page import="com.gzgi.workflow.jbpm.context.*" %>
<%@ page import="com.gzgi.workflow.jbpm.service.*" %>
<%@ page import="com.gzgi.workflow.jbpm.container.*" %>
<%@ page import="com.gzgi.framework.util.*" %>
<%@ page import="org.apache.commons.lang.*" %>
<%@ page import="EDU.oswego.cs.dl.util.concurrent.Semaphore" %>
<%@ include file="/pages/system/checkAdmin.jsp"%>
<%!
  final static Semaphore semaphore = new Semaphore(50); 
%>
<%
        String actorId = request.getParameter("actorId");
		if(actorId == null){
			actorId = "admin";
		}
		try {
			semaphore.acquire();
			List list = ProcessContainer.getContainer().getTaskItems(actorId);
			out.println(list);
			System.out.println(list);
		}catch (Exception ex) {
			ex.printStackTrace();
			throw new RuntimeException(ex);
		} finally {
			semaphore.release();
	    }
%>